<!--
  描述：员工档案详情页
  @author tanghongjun
  @since 2020-05-14 10:48:18
-->
<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<head th:include="common/common :: jscss">
    <title>新增或编辑分类</title>
    <style>
        .layui-form-radio {
            line-height: 28px;
            margin: 6px 10px 0 20px;
            padding-right: 10px;
            cursor: pointer;
            font-size: 0;
        }
    </style>
</head>
<body>

<div class="layui-fluid">

    <blockquote class="layui-crumb">组织关系&nbsp;&nbsp;>
        <a lay-href="/mc/staff/list.action">员工管理</a>&nbsp;&nbsp;>&nbsp;
        <zmn th:text="${obj.staffName}"></zmn>&nbsp;&nbsp;>&nbsp;
        <zmn th:text="${(staffArchives.archivesId > 0) ? '修改员工档案' : '新增员工档案'}"></zmn>
    </blockquote>

    <div class="layui-card">

        <div th:replace="mc/staff/_tab::tab"></div>

        <form method="post" action="" class="layui-form" lay-filter="zmn-form">

            <input type="hidden" name="archivesId" th:value="${staffArchives.archivesId}"/>
            <input type="hidden" name="staffId" th:value="${staffArchives.staffId}"/>

            <div class="layui-card-header" style="margin-top:10px;"><b>身份信息</b></div>
            <div class="layui-split">&nbsp;</div>
            <div class="layui-form-item">
                <label class="layui-form-label">身份证号码：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" id="idCardNumber" name="idCardNumber" th:value="${staffArchives.idCardNumber}"
                               placeholder="身份证号码"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">身份证地址：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="idCardAdress" th:value="${staffArchives.idCardAdress}"
                               placeholder="身份证地址"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">证件有效期类型：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline" style="width: 590px">
                        <input type="radio" name="idCardValidityType" value="1" title=""
                               th:checked="${staffArchives.idCardValidityType == 1}">
                        <input type="text" name="idCardValidityTime" id="idCardValidityTime"
                               th:value="${staffArchives.idCardValidityTime}"
                               style=" height: 30px; line-height: 38px ;  border-width: 1px; border-color: #e6e6e6; background-color: #fff;padding-left: 10px;"
                               placeholder="yyyy-MM-dd" autocomplete="off"/>
                        <input type="radio" name="idCardValidityType" value="2" title="长期" style="margin-left: 20px"
                               th:checked="${staffArchives.idCardValidityType == 2 || staffArchives.idCardValidityType == null }">
                    </div>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">户籍类型：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <select name="residenceType" lay-search="">
                            <option value="">请选择</option>
                            <option th:each="item:${residenceTypes}" th:value="${item.key}" th:text="${item.value}"
                                    th:selected="${item.key == staffArchives.residenceType}"></option>
                        </select>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">户籍所在地：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="registeredPermanentResidence"
                               th:value="${staffArchives.registeredPermanentResidence}" placeholder="户籍所在地"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">住址：</label>
                <div class="layui-input-inline">
                    <select name="provinceId" id="provinceId" lay-filter="provinceId" lay-search>
                        <option value="">-选择-</option>
                        <option th:each="province:${provinces}" th:value="${province.areaId}"
                                th:selected="${province.areaId == staffArchives.provinceId}"
                                th:text="${province.name}"></option>
                    </select>
                </div>
                <div class="layui-input-inline">
                    <select name="cityId" id="cityId" lay-filter="cityId" lay-search>
                        <option value="">-选择-</option>
                        <option th:each="city:${citys}" th:value="${city.areaId}"
                                th:selected="${city.areaId == staffArchives.cityId}" th:text="${city.name}"></option>
                    </select>
                </div>
                <div class="layui-input-inline">
                    <select name="countryId" id="countryId" lay-filter="countryId" lay-search>
                        <option value="">-选择-</option>
                        <option th:each="country:${countrys}" th:value="${country.areaId}"
                                th:selected="${country.areaId == staffArchives.cityId}"
                                th:text="${country.name}"></option>
                    </select>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">家庭详细地址：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="address" th:value="${staffArchives.address}" placeholder="家庭详细地址"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">出生日期：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="birthday" id="birthday" th:value="${staffArchives.birthday}"
                               class="layui-input" placeholder="yyyy-MM-dd" autocomplete="off"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">性别：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="radio" name="sexType" value="1" title="男"
                               th:checked="${staffArchives.sexType == 1}">
                        <input type="radio" name="sexType" value="2" title="女"
                               th:checked="${staffArchives.sexType == 2 || staffArchives.sexType == null }">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">民族：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="nationType" th:value="${staffArchives.nationType}" placeholder="民族"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">证件照信息：</label>
                <div class="layui-input-inline">
                    <div style="text-align: center">
                        <div class="layui-upload-drag" id="idcardImgSrc">
                            <input type="hidden" id="idcardImgSrcValue" name="idcardImgSrc">
                            <i class="layui-icon"></i>
                            <p>身份证正面</p>
                        </div>
                        <div class="layui-inline">
                            <i onclick="previewImg('idcardImgSrcValue')"
                               class="layui-icon layui-icon-search btn-review"></i>
                            <br>
                            <i onclick="deleteImg('idcardImgSrc')"
                               class="layui-icon layui-icon-delete btn-del funcClass"></i>
                            <br>
                        </div>
                    </div>
                </div>

                <div class="layui-input-inline">
                    <div style="text-align: center">
                        <div class="layui-upload-drag" id="idcardImgSrc2">
                            <input type="hidden" id="idcardImgSrcValue2" name="idcardImgSrc2">
                            <i class="layui-icon"></i>
                            <p>身份证反面</p>
                        </div>
                        <div class="layui-inline">
                            <i onclick="previewImg('idcardImgSrcValue2')"
                               class="layui-icon layui-icon-search btn-review"></i>
                            <br>
                            <i onclick="deleteImg('idcardImgSrc2')"
                               class="layui-icon layui-icon-delete btn-del funcClass"></i>
                            <br>
                        </div>
                    </div>
                </div>
                <div class="layui-input-inline">
                    <div style="text-align: center">
                        <div class="layui-upload-drag" id="idcardImgSrc3">
                            <input type="hidden" id="idcardImgSrcValue3" name="idcardImgSrc3">
                            <i class="layui-icon"></i>
                            <p>个人形象照</p>
                        </div>
                        <div class="layui-inline">
                            <i onclick="previewImg('idcardImgSrcValue3')"
                               class="layui-icon layui-icon-search btn-review"></i>
                            <br>
                            <i onclick="deleteImg('idcardImgSrc3')"
                               class="layui-icon layui-icon-delete btn-del funcClass"></i>
                            <br>
                        </div>
                    </div>
                </div>
            </div>

            <div class="layui-card-header" style="margin-top:10px;"><b>银行信息</b></div>
            <div class="layui-split">&nbsp;</div>

            <div class="layui-form-item">
                <label class="layui-form-label">开户行：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="bankName" th:value="${staffArchives.bankName}" placeholder="开户行信息"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">银行户名：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="bankAccountName" th:value="${staffArchives.bankAccountName}"
                               placeholder="开户行信息"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">银行卡号：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="bankCardNoVarchar" th:value="${staffArchives.bankCardNoVarchar}"
                               placeholder="银行卡号"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>

            <div class="layui-card-header" style="margin-top:10px;"><b>社保信息</b></div>
            <div class="layui-split">&nbsp;</div>
            <div class="layui-form-item">
                <label class="layui-form-label">是否办理社保：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="radio" name="haveSocialSecurity" value="1" title="否"
                               th:checked="${staffArchives.haveSocialSecurity == 1}">
                        <input type="radio" name="haveSocialSecurity" value="2" title="是"
                               th:checked="${staffArchives.haveSocialSecurity == 2 || staffArchives.haveSocialSecurity == null }">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">社保号：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="socialSecurityNumber" th:value="${staffArchives.socialSecurityNumber}"
                               placeholder="社保号"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">参保时间：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="socialSecurityStartTime" id="socialSecurityStartTime"
                               th:value="${staffArchives.socialSecurityStartTime}" class="layui-input"
                               placeholder="yyyy-MM-dd" autocomplete="off"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">停保时间：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="socialSecurityStopTime" id="socialSecurityStopTime"
                               th:value="${staffArchives.socialSecurityStopTime}" class="layui-input"
                               placeholder="yyyy-MM-dd" autocomplete="off"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">停保原因：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="socialSecurityStopReason"
                               th:value="${staffArchives.socialSecurityStopReason}" placeholder="停保原因"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>

            <div class="layui-card-header" style="margin-top:10px;"><b>学历信息</b></div>
            <div class="layui-split">&nbsp;</div>
            <div class="layui-form-item">
                <label class="layui-form-label">最高学历：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <select name="highestEdu" lay-search="">
                            <option value="">请选择</option>
                            <option th:each="item:${eduList}" th:value="${item.key}" th:text="${item.value}"
                                    th:selected="${item.key == staffArchives.highestEdu}"></option>
                        </select>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">是否统招：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="radio" name="recruitment" value="1" title="否"
                               th:checked="${staffArchives.recruitment == 1}">
                        <input type="radio" name="recruitment" value="2" title="是"
                               th:checked="${staffArchives.recruitment == 2 || staffArchives.recruitment == null }">
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">毕业院校：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="graduateSchool" th:value="${staffArchives.graduateSchool}"
                               placeholder="毕业院校"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">毕业时间：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="graduationTime" id="graduationTime"
                               th:value="${staffArchives.graduationTime}" class="layui-input"
                               placeholder="yyyy-MM-dd" autocomplete="off"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">所学专业：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="major" th:value="${staffArchives.major}" placeholder="所学专业"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>

            <div class="layui-card-header" style="margin-top:10px;"><b>其他信息</b></div>
            <div class="layui-split">&nbsp;</div>
            <div class="layui-form-item">
                <label class="layui-form-label">年龄：</label>
                <div class="layui-input-inline">
                    <input type="text" id="age" name="age" th:value="${staffArchives.age}" placeholder="年龄"
                           autocomplete="off" class="layui-input" maxlength="100"/>
                </div>
                <label class="layui-form-label">邮编：</label>
                <div class="layui-input-inline">
                    <input type="text" name="zipCode" th:value="${staffArchives.zipCode}" placeholder="邮编"
                           autocomplete="off" class="layui-input" maxlength="100"/>
                </div>

            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">婚姻状况：</label>

                <div class="layui-input-inline">
                    <select name="marriageStatus" lay-search="">
                        <option value="">请选择</option>
                        <option th:each="item:${marriageList}" th:value="${item.key}" th:text="${item.value}"
                                th:selected="${item.key == staffArchives.marriageStatus}"></option>
                    </select>
                </div>

                <label class="layui-form-label">健康状况：</label>

                <div class="layui-input-inline">
                    <input type="text" name="healthyStatus" th:value="${staffArchives.healthyStatus}"
                           placeholder="健康状况"
                           autocomplete="off" class="layui-input" maxlength="100"/>
                </div>

            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">政治面貌：</label>
                <div class="layui-input-inline">
                    <select name="politicalStatus" lay-search="">
                        <option value="">请选择</option>
                        <option th:each="item:${politicalList}" th:value="${item.key}" th:text="${item.value}"
                                th:selected="${item.key == staffArchives.politicalStatus}"></option>
                    </select>
                </div>
                <label class="layui-form-label">专业职称：</label>
                <div class="layui-input-inline">
                    <input type="text" name="professionalTitle" th:value="${staffArchives.professionalTitle}"
                           placeholder="专业职称"
                           autocomplete="off" class="layui-input" maxlength="100"/>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">首次参加工作时间：</label>
                <div class="layui-input-inline">
                    <input type="text" name="joinWorkingTime" id="joinWorkingTime"
                           th:value="${staffArchives.joinWorkingTime}" class="layui-input"
                           placeholder="yyyy-MM-dd" autocomplete="off"/>
                </div>
                <label class="layui-form-label">英语等级：</label>
                <div class="layui-input-inline">
                    <input type="text" name="englishLevel" th:value="${staffArchives.englishLevel}"
                           placeholder="英语等级"
                           autocomplete="off" class="layui-input" maxlength="100"/>
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">身高（cm）：</label>
                <div class="layui-input-inline">
                    <input type="text" name="height" th:value="${staffArchives.height}" placeholder="身高"
                           autocomplete="off" class="layui-input" maxlength="100"/>
                </div>
                <label class="layui-form-label">驾照等级：</label>
                <div class="layui-input-inline">
                    <input type="text" name="driverLicenseLevel" th:value="${staffArchives.driverLicenseLevel}"
                           placeholder="驾照等级"
                           autocomplete="off" class="layui-input" maxlength="100"/>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">体重（kg）：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline">
                        <input type="text" name="weight" th:value="${staffArchives.weight}" placeholder="体重"
                               autocomplete="off" class="layui-input" maxlength="100"/>
                    </div>
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">个人爱好及特长：</label>
                <div class="layui-input-block">
                    <div class="layui-input-inline" style="width: 600px">
                         <textarea placeholder="个人爱好及特长" maxlength="100" th:text="${staffArchives.hobbiesSpecialties}"
                                   id="hobbiesSpecialties" name="hobbiesSpecialties"
                                   class="layui-textarea"></textarea>
                    </div>
                </div>
            </div>

            <zmn th:if="${staffArchives.archivesId > 0}">
                <div class="layui-card-header"><b>其他信息</b></div>
                <div class="layui-split">&nbsp;</div>
                <div class="layui-form-item layui-form-item-xs">
                    <label class="layui-form-label">修改人/时间</label>
                    <div class="layui-input-block">
                        <div class="layui-form-mid layui-word-aux"
                             th:text="${staffArchives.updater} + '&nbsp;/&nbsp;' + ${#dates.format(staffArchives.updateTime, 'yyyy-MM-dd HH:mm:ss')}">
                            修改人/时间
                        </div>
                    </div>
                </div>
                <div class="layui-form-item layui-form-item-xs">
                    <label class="layui-form-label">创建人/时间</label>
                    <div class="layui-input-block">
                        <div class="layui-form-mid layui-word-aux"
                             th:text="${staffArchives.creater} + '&nbsp;/&nbsp;' + ${#dates.format(staffArchives.createTime, 'yyyy-MM-dd HH:mm:ss')}">
                            创建人/时间
                        </div>
                    </div>
                </div>
            </zmn>

            <div class="layui-split">&nbsp;</div>
            <div class="layui-form-item layui-layout-admin">
                <div class="layui-input-block">
                    <div class="layui-footer" style="left: 0;">
                        <button class="layui-btn" lay-submit="" lay-filter="zmn-form-submit">保存
                            <!--      <button class="layui-btn" lay-submit="" lay-filter="zmn-form-submit"th:if="${#authPermit.checkPermit('/staff/staffarchives/addEdit.action')}">保存-->

                        </button>
                        <button class="layui-btn layui-btn-primary" id="cancleBtn">
                            取消
                        </button>
                    </div>
                </div>
            </div>

        </form>

    </div>

</div>

<script type="text/javascript" th:inline="javascript">

    var json = {
        staffArchives: [[${staffArchives}]]
    };

    layui.config({
        base: "/static/lay/",
        version: "202005261108"
    }).extend({
        index: "lib/index",
        plat_staffarchives_detail: "staff/staffarchives/zmn.plat.staffarchives.detail"
    }).use(['index', 'plat_staffarchives_detail']);

</script>
</body>
</html>